apiVersion: networking.istio.io/v1alpha3
kind: Gateway
metadata:
  name: ${gatewayName}
  namespace: ${namespace}
<#if resourceVersion??>
  resourceVersion: "${resourceVersion}"
</#if>
spec:
  selector:
    istio: ingressgateway
  servers:
<#if httpFlag>
  - port:
      number: 80
      name: http
      protocol: HTTP
    hosts:
    - ${domain}
</#if>
<#if httpsFlag>
  - port:
      number: 443
      name: https
      protocol: HTTPS
    hosts:
    - ${domain}
    tls:
      mode: SIMPLE
      credentialName: ${tslCert}
</#if>